# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=imlib2
pkgver=1.9.1
pkgrel=0
pkgdesc="Image manipulation library"
url="https://sourceforge.net/projects/enlightenment"
arch="all"
license="Imlib2"
subpackages="$pkgname-dev"
depends_dev="freetype-dev libxext-dev libsm-dev"
makedepends="$depends_dev tiff-dev giflib-dev bzip2-dev libpng-dev
	libid3tag-dev libjpeg-turbo-dev zlib-dev util-linux-dev libwebp-dev"
source="https://downloads.sourceforge.net/enlightenment/imlib2-$pkgver.tar.gz"

build() {
	./configure \
		--build=$CBUILD \
		--host=$CHOST \
		--prefix=/usr \
		--sysconfdir=/etc/imlib2 \
		--x-libraries=/usr/lib \
		--disable-mmx \
		--disable-amd64 \
		--enable-visibility-hiding \
		--with-x \
		--with-bzip2 \
		--with-gif \
		--with-id3 \
		--with-jpeg \
		--with-png \
		--with-tiff \
		--with-webp \
		--with-zlib
	make
}

check() {
	make check
}

package() {
	make DESTDIR=$pkgdir install
}

sha512sums="
892c9f37e814f5524ad9fe492bf3040ad40adad874e639d5ab28fc8a67975141a432df5c0cdfe266c4ae525a1d060d077443f67e7aa97f13ad9ec69de61c656d  imlib2-1.9.1.tar.gz
"
